package com.fzs.sshd.cli.server.channel;

import org.apache.sshd.common.channel.Channel;
import org.apache.sshd.common.session.Session;
import org.apache.sshd.common.util.threads.CloseableExecutorService;
import org.apache.sshd.common.util.threads.ThreadUtils;
import org.apache.sshd.server.forward.DirectTcpipFactory;

import java.io.IOException;

public class ADBChannelFactory extends DirectTcpipFactory {

    @Override
    public Channel createChannel(Session session) throws IOException {
        // type 可以根据你需求选择 LOCAL / REMOTE
        return new LoggingTcpipServerChannel(getType(), ThreadUtils.noClose(getExecutorService()));
    }


    @Override
    public CloseableExecutorService getExecutorService() {
        return null;
    }
}
